<include file="Public:pagerForm" />
<script type="text/javascript">
	function reload4() {
		navTab.reload("__URL__", {});
	}
	function condbltable(target, rel) {
		if (target == 'sid_contract') {
			$.pdialog.open("__URL__/read/id/" + rel + "/contractedit=" + rel,
					"pdialogid", "查看合同", {
						max : false,
						mask : true,
						width : 720,
						height : 350
					});
		}
	}
</script>
<div class="pageHeader">
	<form onsubmit="return navTabSearch(this);" rel="pagerForm"
		action="__URL__" method="post">
		<input type="hidden" name="start" value="{$start}" />
		<input	type="hidden" name="end" value="{$end}" />
		<input	type="hidden" name="contractno" value="{$contractno}" />
		<input	type="hidden" name="type" value="{$type}" />
		<input	type="hidden" name="businesstype" value="{$businesstype}" />
		<input	type="hidden" name="secondname" value="{$secondname}" />
		<div class="searchBar">
			<ul class="searchContent">
			</ul>
			<div class="subBar">
				<ul>
					<li><a class="button" href="__URL__/retrieval" target="dialog"
						mask="true" rel="closeCurrent" title="查询框"><span>高级查询</span></a></li>
				</ul>
			</div>
		</div>
	</form>
</div>

<div class="pageContent">
	<div class="panelBar">
		<ul class="toolBar">
<!-- 
			<li><a class="add" href="__URL__/add" target="dialog" rel="add"
				mask="true" width="540"><span>新增</span></a></li>
				 -->
			<li><a class="add"  href="__URL__/remind" target="navTab" 
				rel = "remind" mask="true" width="540" height="450"><span>拟定合同</span></a></li>
			<!--
			<li><a class="add" href="__URL__/remind" target="navTab"  rel="remind" mask="true"><span>拟定合同</span></a></li>
			 <li><a class="delete"
				href="__URL__/forbid/id/{sid_contract}/navTabId/__MODULE__"
				target="ajaxTodo" title="你确定要作废吗？"><span>作废</span></a></li> -->


			<li><a class="delete"
				href="__URL__/delete/navTabId/__MODULE__"
				target="selectedTodo" postType="string" title="你确定要删除吗？"
				warn="请选择信息"><span>删除</span></a></li>
			<li><a class="edit" href="__URL__/edit/id/{sid_contract}"
				target="dialog" mask="true" rel="contractedit" warn="请选择记录" width="540"><span>修改</span></a></li>
			<li class="line">line</li>
               <!-- 
			<li><a class="add" href="__URL__/approve/id/{sid_contract}"
				target="dialog" mask="true"><span>审批</span></a></li> 
				-->
			<li><a class="add" href="__URL__/progress/id/{sid_contract}"
				target="dialog" width="620" height="380" mask="true"><span>合同进度</span></a></li>
			<li><a class="icon" href="__URL__/export/start/{$start}/end/{$end}/contractno/{$contractno}/type/{$type}/projectid/{$projectid}/secondname/{$secondname}" target="dwzExport" targetType="navTab" title="实要导出这些记录吗?"><span>导出EXCEL</span></a></li>
			<li><a class="icon" href="#" onclick="reload4()"><span>刷新</span></a></li>
			<li><a class="add" href="__URL__/addnote/id/{sid_contract}"
				target="dialog" mask="true" rel="contractnote" warn="请选择记录" width="540" height="250"><span>增加备注</span></a></li>
			<li><a class="icon" href="__URL__/trash" target="navTab" mask="true" rel="contract_trash" title="回收站" width="540" height="320"><span>回收站</span></a></li>
		</ul>
	</div>


	<table class="table" width="100%" layoutH="136">
		<thead>
			<tr>
				<th width="20" align="center"><input type="checkbox"
					group="ids" class="checkboxCtrl"></th>
				<th width="100" align="center">合同编号</th>
				<th width="100" align="center">合同类型</th>
				<th width="100" align="center">客户名称</th>
				<!--  <th width="100" align="center">合同金额</th>-->
				<th width="100" align="center">录入人</th>
				<th width="100" align="center">收货人</th>
				<th width="60" align="center">状态</th>
				<th width="60" align="center">备注</th>
				<th width="150" align="center">操作</th>
			</tr>
		</thead>
		<tbody>
			<define name="number" value="1" />
			<volist id="vo" name="list">
			<tr target="sid_contract" rel="{$vo['id']}"
				ondblclick="condbltable('sid_contract',{$vo.id})">
				<td><input type="checkbox" name="ids" value="{$vo['id']}" /></td>
				<td><a>{$vo['contractno']}</a></td>
				<!-- <td><a href="__URL__/index/id/{$vo['id']}/" target="navTab" rel="__MODULE__">{$vo['subject']}</a></td> -->
				<td>
				{$vo.businesstype}
				</td>
				<td>{$vo['secondname']}</td>
				<!--  <td>{$vo['totalprice']}</td>-->
				<td>{$vo['creator']}</td>
				<td>{$vo['consignee']}</td>
				<!-- <td>
				<eq name="vo['status']" value="1">待审批</eq>
				<eq name="vo['status']" value="0">已作废</eq>
				<eq name="vo['status']" value="2">审批通过</eq>
				<eq name="vo['status']" value="3">拒绝审批</eq>
				</td> -->
				
				<td><if condition="$vo['status'] eq 101">待审批</if>  <if
						condition="$vo['status'] eq 100">审批完成</if> <if
						condition="$vo['status'] eq 300">拒绝审批</if> <if
						condition="$vo['status'] neq 300 and $vo['status'] neq 100 and $vo['status'] neq 101">
					{$vo['status']}% </if></td>
				<td>{$vo['note']}</td>
				<td> 
					<a href="__URL__/uploadify/ids/{$vo['id']}/navTabId/__MODULE__" target="dialog" width="620" height="380" mask="true"><span>上传附件</span></a>&nbsp;
					|&nbsp;
					<a href="__URL__/downloadfile/ids/{$vo['id']}/navTabId/__MODULE__" target="dialog" width="700" height="300" mask="true"><span>下载附件</span></a>&nbsp;
			</tr>
			</volist>
		</tbody>
	</table>

	<div class="panelBar">
		<div class="pages">
			<span>每页</span> <select class="combox" name="numPerPage"
				onchange="navTabPageBreak({numPerPage:this.value})">
				<eq name="numPerPage" value="24">
				<option value="24" selected>24</option>
				<else />
				<option value="24">24</option>
				</eq>
				<eq name="numPerPage" value="50">
				<option value="50" selected>50</option>
				<else />
				<option value="50">50</option>
				</eq>
				<eq name="numPerPage" value="100">
				<option value="100" selected>100</option>
				<else />
				<option value="100">100</option>
				</eq>
				<eq name="numPerPage" value="200">
				<option value="200" selected>200</option>
				<else />
				<option value="200">200</option>
				</eq>
			</select> <span>条，共{$totalCount}条</span>
		</div>

		<div class="pagination" targetType="navTab" totalCount="{$totalCount}"
			numPerPage="{$numPerPage}" pageNumShown="10"
			currentPage="{$currentPage}"></div>

	</div>
</div>

